clear;clc;

% Askisi 1:
% 
% Oi 7 prwtoi oroi ths seiras Taylor gia thn f(x)=-log(1-x).
syms x
apotelesma1=taylor('-log(1-x)',x,7)

% Oi 7 prwtoi oroi ths seiras Taylor gia thn g(y)=exp(y)/cos(y) + tan(y)^3.
syms y
apotelesma2=taylor('exp(y)/cos(y) + tan(y)^3',y,7)


% Askisi 2:

clear x;syms x;

for k =-3:1:3
    
    apotelesma3=int((x^2-4)*exp(-i*k*x),x,-pi,pi)/(2*pi)
end

% Askisi 3:   

b0=(1/6)*(1*exp(-i*2*pi*0/6*1)+1*exp(-i*2*pi*0/6*3)+1*exp(-i*2*pi*0/6*5));
b1=(1/6)*(1*exp(-i*2*pi*1/6*1)+1*exp(-i*2*pi*1/6*3)+1*exp(-i*2*pi*1/6*5));
b3=(1/6)*(1*exp(-i*2*pi*3/6*1)+1*exp(-i*2*pi*3/6*3)+1*exp(-i*2*pi*3/6*5));
b5=(1/6)*(1*exp(-i*2*pi*5/6*1)+1*exp(-i*2*pi*5/6*3)+1*exp(-i*2*pi*5/6*5)); 

p=0;

for n =0:1:6
    for m =1:1:6
        f=b1*exp(i*2*pi*m/6*n);
        p=p+f;
    end
    p
end

